package com.fitbet.admin.service.bet;

import java.text.ParseException;
import java.util.List;

import com.demo2do.core.entity.page.Page;
import com.fitbet.admin.dto.BetRequest;
import com.fitbet.admin.service.DataService;
import com.fitbet.entity.bet.Bet;
import com.fitbet.entity.bet.UserBet;
/**
 * 
 * @author sjh
 *
 */
public interface BetService extends DataService<Bet>{

	/**
	 * 
	 * @return
	 */
	public int count();
	
	/**
	 * 
	 * @return
	 */
	public List<Bet> list(Page page);
	
	/**
	 * 
	 * @param id
	 * @return
	 */
	public List<UserBet> listById(Long id);
	
	
	/**
	 * 
	 * @param bet
	 * @throws ParseException 
	 */
	public void create(BetRequest betRequest) throws ParseException;
	
	/**
	 * 
	 * @param id
	 */
	public void open(Long id); 
	
	/**
	 * 
	 * @param id
	 */
	public void close(Long id);
	
	/**
	 * 
	 * @param id
	 */
	public void editCover(Long id, String media);
}
